package com.pentofab.payrollmanagement.dao.model;

import java.util.ArrayList;

public class LeaveDetail {
	
	private String Select; 
	private String LEAVE_TYPE;
    private String FROM_DATE; 
    private String TO_DATE; 
    private String number; 
    private String Reason;
	
    
    public LeaveDetail(String leaveType, String fromDate,String toDate,String number,String reason) {
    	
    	this.LEAVE_TYPE = leaveType;
    	this.FROM_DATE =fromDate;
    	this.TO_DATE = toDate;
    	this.number =number;
    	this.Reason =reason;
	}


	public static ArrayList<LeaveDetail> getLeaveDetailList(
			ArrayList<Leave> leaveList) {
    	
		ArrayList<LeaveDetail> detail = new ArrayList<LeaveDetail>();
		
		for (int i = 0; i < leaveList.size(); i++) {
			Leave cur = leaveList.get(i);
			detail.add(new LeaveDetail(cur.getLeaveType(),
					cur.getFromDate(),cur.getToDate(),String.valueOf(cur.getNoOfDays()),cur.getReson()));
		}
		
		return detail;

	}

	public String getSelect() {
		return Select;
	}


	public void setSelect(String select) {
		Select = select;
	}


	public String getLEAVE_TYPE() {
		return LEAVE_TYPE;
	}


	public void setLEAVE_TYPE(String lEAVE_TYPE) {
		LEAVE_TYPE = lEAVE_TYPE;
	}


	public String getFROM_DATE() {
		return FROM_DATE;
	}


	public void setFROM_DATE(String fROM_DATE) {
		FROM_DATE = fROM_DATE;
	}


	public String getTO_DATE() {
		return TO_DATE;
	}


	public void setTO_DATE(String tO_DATE) {
		TO_DATE = tO_DATE;
	}


	public String getNumber() {
		return number;
	}


	public void setNumber(String number) {
		this.number = number;
	}


	public String getReason() {
		return Reason;
	}


	public void setReason(String reason) {
		Reason = reason;
	}
	
	
}
